<form name="form_admin" method="POST" action="<?php echo formEditAction()?>">
    <input type="hidden" name="id" value="<?php echo $newsletter['iId']?>" />
    <div id="Tabs_Pages">
        <div class="Page">
        <table width="100%">
            <tr>
                <td width="10%"><b>Url: </b> </td>
                <td width="90%">
                	<input class="normal3" type="text" name="Url" value="<?echo $newsletter['cUrlString']?>"/>
                    &nbsp;&nbsp;&nbsp;
                    <b>Email Test:</b>
                    <input name="EmailTest" id="EmailTest" class="normal2" style="width: 160px;" /> 
                    <input type="button" value="Test" onclick="testNewslt()" id="butsendtest" />        
                </td>
            </tr>
        	<tr>
                <td width="10%"><b>Title: </b> </td>
                <td width="90%">
                	<input class="normal3" type="text" name="Title" id="Title" value="<?echo $newsletter['cName']?>"/>        
        			<b>Status</b>
        			<select name="Status">
        				<?echo liststatus($newsletter['iStatus'])?>
        			</select>
                </td>
            </tr>
            <tr>
                <td><b>Image Thumb</b></td>
                <td><?php echo inputFile('ImgIntroThumb',$newsletter["cImageThumb"])?></td>
            </tr>
            <tr>
                <td><b>Image</b></td>
                <td><?php echo inputFile('ImgIntro',$newsletter["cImage"])?></td>
            </tr>
            <tr>
              <td ><strong>Message:</strong></td>
              <td>
        		  <textarea name="Message" id="Message" 
                  style="height:500px; width:99%"><?php echo $newsletter['cDescription']?></textarea>
        	  </td>
            </tr>
            <tr>
              <td ><strong>Footer:</strong></td>
              <td>
        		  <textarea name="Footer" id="Footer" 
                  style="height:500px; width:99%"><?php echo $newsletter['cFooter']?></textarea>
        	  </td>
            </tr>
            	<tr>
                    <td><b><?php echo _METATITLE?></b></td>
                    <td><input class="normal3" style="width:90%" type="text" name="MetaTitle" id="MetaTitle"
            		value="<?php echo $newsletter["cMetaTitle"] ?>" /></td>
                </tr>
            
                <tr>
                    <td><b><?php echo _METAKEYWORDS?></b></td>
                    <td><input class="normal3" style="width:90%" type="text" name="MetaKeywords" id="MetaKeywords"
            		 value="<?php echo $newsletter["cMetaKeywords"] ?>"  /></td>
                </tr>
            
                <tr>
                    <td valign="top" style="vertical-align:top"><b>Meta Description</b></td>
                    <td style="padding-bottom:10"><textarea style="height:90px; width:90%;" class="noeditor"
            		 name="MetaDescription" ><?php echo $newsletter["cMetaDescription"] ?></textarea></td>
            	</tr>		
        </table>
        </div>            
    </div>        
</form>
<script>
var ajaxtest=new ajaxLoader;
function testNewslt()
{
    if(getId('EmailTest').value=='')
    {
        alert("please enter email");
        return;
    }
    ajaxtest.init({url:location.href,func:testsucc});
    ajaxtest.send('opt=test&email='+getId('EmailTest').value);
    getId('butsendtest').value='Sending...';
}
function testsucc(obj)
{
    getId('butsendtest').value='Test';
    alert(obj);
}
</script>